package com.vick.tool;

import java.io.ByteArrayOutputStream;
import java.io.IOException;
import java.math.BigInteger;

import android.graphics.Bitmap;

public class BitmapTool {
	public static String bitMapToString(Bitmap bmp){
		ByteArrayOutputStream out = new ByteArrayOutputStream();
		bmp.compress(Bitmap.CompressFormat.PNG, 100, out);
		try {
			out.flush();
			out.close();
		} catch (IOException e) {
			e.printStackTrace();
			return null;
		}
        return (new BigInteger(1,out.toByteArray())).toString(16);
	}
}
